package liangtWorkSpace.lambda;

/**
 * @ClassName Apple
 * @Description : 功能说明
 * @Author : LiangT
 * @Date : 2020/4/14 19:14
 */
public class Apple {
    private int weight;
    private String color;

    @Override
    public String toString() {
        return "Apple{" +
                "weight=" + weight +
                ", color='" + color + '\'' +
                '}';
    }

    public Apple() {
    }

    public Apple(int weight, String color) {
        this.weight = weight;
        this.color = color;
    }

    public Apple(int weight) {
        this.weight = weight;
    }

    public static Apple redApple(){
        return new Apple(105,"red");
    }
    public int getWeight() {
        return weight;
    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

    public void setWeight(int weight) {
        this.weight = weight;
    }
}
